home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 21 / Cream of the Crop 21 (Terry Blount) (October 1996).iso / utility / s48v13.zip / DEMO.ASM < prev    next >
Assembly Source File  |  1996-07-23  |  809b  |  39 lines

  1.          .org   0
  2.          nop    
  3.          jmp    start
  4.          .org   3
  5.          nop
  6.          nop
  7.          jmp    intsvc
  8.          .org   7
  9.          jmp    tmrsvc
  10. ; Initialization
  11. start    clr    a
  12.          mov    r0,a
  13.          mov    r1,a
  14.          mov    r3,a
  15.          mov    t,a
  16.          mov    r0,#24
  17.          mov    @r0,a
  18.          en     tcnti
  19.          strt   t
  20.          en     i
  21. ; Main Loop
  22. loop     inc    r0
  23.          mov    a,r0
  24.          jnz    loop
  25.          inc    r1
  26.          jmp    loop
  27. ; External Interrupt Service Routine
  28. intsvc   mov    a,r0
  29.          sel    rb1
  30.          movx   @r0,a
  31.          inc    r0
  32.          sel    rb0
  33.          retr
  34. ; Timer Overflow Interrupt Service Routine
  35. tmrsvc   inc    r3
  36.          retr
  37.          .end
  38.                             
  39.